package org.pay.core.service;

import org.pay.core.entity.MchTradeOrder;

import java.util.List;

/**
 * @author: yangshancheng
 * @date: 17/12/21
 * @description:
 */
public interface IMchTradeOrderService {

    List<MchTradeOrder> select(int pageIndex, int pageSize, MchTradeOrder mchTradeOrder);

    int count(MchTradeOrder mchTradeOrder);

    int add(MchTradeOrder mchTradeOrder);

    MchTradeOrder findByTradeOrderId(String tradeOrderId);

    MchTradeOrder findByMchIdAndTradeOrderId(Long mchId, String tradeOrderId);

    MchTradeOrder findByMchIdAndPayOrderId(Long mchId, String payOrderId);

    int updateStatus4Success(String tradeOrderId);

    int updateStatus4Complete(String tradeOrderId);

    int update(MchTradeOrder mchTradeOrder);

}
